package com.looking;

import java.util.Random;

/**
 * Created by Administrator on 2017/1/10.
 */
public class Product {

    private Random random = new Random();

    public String productFun() {
        Persist persist = new DemoPersist();
        Warehouse warehouse = new Warehouse(persist);
        int who = random.nextInt(warehouse.getLenWho());
        int where = random.nextInt(warehouse.getLenWhere());
        int what = random.nextInt(warehouse.getLenWhat());
        String talk = warehouse.getWho().get(who) + "---";
        talk += warehouse.getWhere().get(where) + "---";
        talk += warehouse.getWhat().get(what);
        return talk;
    }
}
